<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:import href="../utilities/master-calendar.xsl"/>
<xsl:import href="../utilities/date-and-time.xsl"/>
<xsl:import href="../utilities/get-admin-menu.xsl"/>
<xsl:import href="../utilities/get-admin-print-schedule.xsl"/>
<xsl:import href="../utilities/get-tomorrow.xsl"/>


<xsl:template match="data">
	<xsl:param name="tomorrow">
		<xsl:call-template name="next-day">
			<xsl:with-param name="date" select="$today"/>
		</xsl:call-template>
	</xsl:param>
	
	<div class="grid_16" id="admin">
		<xsl:if test="/data/clients/entry/administrator = 'Yes'">
			<div class="grid_5 alpha">
				<xsl:call-template name="admin-menu"/>
			</div>
			
			<div class="grid_11 omega">
				<xsl:choose>
					<xsl:when test="$entry-id = '' or $entry-id = 'today' or $entry-id = $today">
						<div id="admin_main" class="grid_11">
							<xsl:apply-templates select="admin-print-schedule" mode="print-today"/>
						</div>
					</xsl:when>
					<xsl:when test="$entry-id = 'tomorrow' or $entry-id = $tomorrow">
						<div id="admin_main" class="grid_11">
							<xsl:apply-templates select="admin-print-schedule" mode="print-tomorrow"/>
						</div>
					</xsl:when>
					<xsl:otherwise>
						<div id="admin_main" class="grid_11">
							<xsl:apply-templates select="admin-print-schedule" mode="print-other"/>
						</div>
					</xsl:otherwise>
				</xsl:choose>
			</div>
		</xsl:if>
	</div>
</xsl:template>
</xsl:stylesheet>